home *** CD-ROM | disk | FTP | other *** search
/ Apple Reference & Presen…tion Library 2 (Reseller) / Apple R&P Lib Reseller v2.0.iso / 4-Fonts & Software / Demo Software / AppMaker / Demo AppMaker™ / Demo AppMaker™.rsrc / TmpP_208_ModalDialog.txt < prev    next >
Text File  |  1989-04-09  |  1KB  |  2 lines

  1. # (decoded with TMPL 11972)
  2. { %filename% -- Modal dialog }{ Created %date% %time% by AppMaker }Unit %unitname%;InterfaceUses%If MPW%    {$Load ToolBox.dump}        MemTypes,        QuickDraw,        OSIntf,        ToolIntf,        PackIntf,    {$Load}%end if%%If Think%{$ifc undefined Think_Pascal}    ListManager,{$endc}%end if%    ResourceDefs,    DialogAids;Type    %dlogname%Rec = record        %DeclItems%    end;{----------}Function Get%dlogname% (var %dlogname%:    %dlogname%Rec): boolean;{----------}Implementation%If MPW%{$D+}{$R+}{$OV+}%end if%const    %ConstItems%%If MPW%{$S %unitname%}%end if%%ItemProcs%%MaybeFilter%{----------}Function Get%dlogname% {(var %dlogname%:    %dlogname%Rec): boolean};var    result:            boolean;    theDialog:        DialogPtr;    done:            boolean;    itemNr:            integer;Begin    InitCursor;    theDialog := GetNewDialog (%dlogname%ID, nil, pointer (-1));    SetPort (theDialog);    with %dlogname% do begin        %SetItems%        ShowWindow (theDialog);        OutlineButton (1);        done := false;        while not done do begin            %EnableItems%            ModalDialog (%Filtername%, itemNr);            case itemNr of                %HandleItems%            end; {case}        end; {while}        %FinishItems%    end; {with}    DisposDialog (theDialog);    Get%dlogname% := result;End; {Get%dlogname%}End. {%unitname%}